3.53 \(\int \frac {A+B x+C x^2}{(a+c x^2)^2} \, dx\)

Optimal. Leaf size=69 \[ \frac {(a C+A c) \tan ^{-1}\left (\frac {\sqrt {c} x}{\sqrt {a}}\right )}{2 a^{3/2} c^{3/2}}-\frac {a B-x (A c-a C)}{2 a c \left (a+c x^2\right )} \]

[Out]

1/2*(-a*B+(A*c-C*a)*x)/a/c/(c*x^2+a)+1/2*(A*c+C*a)*arctan(x*c^(1/2)/a^(1/2))/a^(3/2)/c^(3/2)

________________________________________________________________________________________

Rubi [A]  time = 0.04, antiderivative size = 69, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, integrand size = 20, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.150, Rules used = {1814, 12, 205} \[ \frac {(a C+A c) \tan ^{-1}\left (\frac {\sqrt {c} x}{\sqrt {a}}\right )}{2 a^{3/2} c^{3/2}}-\frac {a B-x (A c-a C)}{2 a c \left (a+c x^2\right )} \]

Antiderivative was successfully verified.

[In]

Int[(A + B*x + C*x^2)/(a + c*x^2)^2,x]

[Out]

-(a*B - (A*c - a*C)*x)/(2*a*c*(a + c*x^2)) + ((A*c + a*C)*ArcTan[(Sqrt[c]*x)/Sqrt[a]])/(2*a^(3/2)*c^(3/2))

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 205

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]*ArcTan[x/Rt[a/b, 2]])/a, x] /; FreeQ[{a, b}, x]
&& PosQ[a/b]

Rule 1814

Int[(Pq_)*((a_) + (b_.)*(x_)^2)^(p_), x_Symbol] :> With[{Q = PolynomialQuotient[Pq, a + b*x^2, x], f = Coeff[P
olynomialRemainder[Pq, a + b*x^2, x], x, 0], g = Coeff[PolynomialRemainder[Pq, a + b*x^2, x], x, 1]}, Simp[((a
*g - b*f*x)*(a + b*x^2)^(p + 1))/(2*a*b*(p + 1)), x] + Dist[1/(2*a*(p + 1)), Int[(a + b*x^2)^(p + 1)*ExpandToS
um[2*a*(p + 1)*Q + f*(2*p + 3), x], x], x]] /; FreeQ[{a, b}, x] && PolyQ[Pq, x] && LtQ[p, -1]

Rubi steps

\begin {align*} \int \frac {A+B x+C x^2}{\left (a+c x^2\right )^2} \, dx &=-\frac {a B-(A c-a C) x}{2 a c \left (a+c x^2\right )}-\frac {\int \frac {-A-\frac {a C}{c}}{a+c x^2} \, dx}{2 a}\\ &=-\frac {a B-(A c-a C) x}{2 a c \left (a+c x^2\right )}+\frac {(A c+a C) \int \frac {1}{a+c x^2} \, dx}{2 a c}\\ &=-\frac {a B-(A c-a C) x}{2 a c \left (a+c x^2\right )}+\frac {(A c+a C) \tan ^{-1}\left (\frac {\sqrt {c} x}{\sqrt {a}}\right )}{2 a^{3/2} c^{3/2}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.05, size = 68, normalized size = 0.99 \[ \frac {(a C+A c) \tan ^{-1}\left (\frac {\sqrt {c} x}{\sqrt {a}}\right )}{2 a^{3/2} c^{3/2}}+\frac {-a B-a C x+A c x}{2 a c \left (a+c x^2\right )} \]

Antiderivative was successfully verified.

[In]

Integrate[(A + B*x + C*x^2)/(a + c*x^2)^2,x]

[Out]

(-(a*B) + A*c*x - a*C*x)/(2*a*c*(a + c*x^2)) + ((A*c + a*C)*ArcTan[(Sqrt[c]*x)/Sqrt[a]])/(2*a^(3/2)*c^(3/2))

________________________________________________________________________________________

fricas [A]  time = 0.81, size = 195, normalized size = 2.83 \[ \left [-\frac {2 \, B a^{2} c + {\left (C a^{2} + A a c + {\left (C a c + A c^{2}\right )} x^{2}\right )} \sqrt {-a c} \log \left (\frac {c x^{2} - 2 \, \sqrt {-a c} x - a}{c x^{2} + a}\right ) + 2 \, {\left (C a^{2} c - A a c^{2}\right )} x}{4 \, {\left (a^{2} c^{3} x^{2} + a^{3} c^{2}\right )}}, -\frac {B a^{2} c - {\left (C a^{2} + A a c + {\left (C a c + A c^{2}\right )} x^{2}\right )} \sqrt {a c} \arctan \left (\frac {\sqrt {a c} x}{a}\right ) + {\left (C a^{2} c - A a c^{2}\right )} x}{2 \, {\left (a^{2} c^{3} x^{2} + a^{3} c^{2}\right )}}\right ] \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((C*x^2+B*x+A)/(c*x^2+a)^2,x, algorithm="fricas")

[Out]

[-1/4*(2*B*a^2*c + (C*a^2 + A*a*c + (C*a*c + A*c^2)*x^2)*sqrt(-a*c)*log((c*x^2 - 2*sqrt(-a*c)*x - a)/(c*x^2 +
a)) + 2*(C*a^2*c - A*a*c^2)*x)/(a^2*c^3*x^2 + a^3*c^2), -1/2*(B*a^2*c - (C*a^2 + A*a*c + (C*a*c + A*c^2)*x^2)*
sqrt(a*c)*arctan(sqrt(a*c)*x/a) + (C*a^2*c - A*a*c^2)*x)/(a^2*c^3*x^2 + a^3*c^2)]

________________________________________________________________________________________

giac [A]  time = 0.18, size = 60, normalized size = 0.87 \[ \frac {{\left (C a + A c\right )} \arctan \left (\frac {c x}{\sqrt {a c}}\right )}{2 \, \sqrt {a c} a c} - \frac {C a x - A c x + B a}{2 \, {\left (c x^{2} + a\right )} a c} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((C*x^2+B*x+A)/(c*x^2+a)^2,x, algorithm="giac")

[Out]

1/2*(C*a + A*c)*arctan(c*x/sqrt(a*c))/(sqrt(a*c)*a*c) - 1/2*(C*a*x - A*c*x + B*a)/((c*x^2 + a)*a*c)

________________________________________________________________________________________

maple [A]  time = 0.01, size = 76, normalized size = 1.10 \[ \frac {A \arctan \left (\frac {c x}{\sqrt {a c}}\right )}{2 \sqrt {a c}\, a}+\frac {C \arctan \left (\frac {c x}{\sqrt {a c}}\right )}{2 \sqrt {a c}\, c}+\frac {-\frac {B}{2 c}+\frac {\left (A c -a C \right ) x}{2 a c}}{c \,x^{2}+a} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((C*x^2+B*x+A)/(c*x^2+a)^2,x)

[Out]

(1/2*(A*c-C*a)/a/c*x-1/2*B/c)/(c*x^2+a)+1/2/a/(a*c)^(1/2)*arctan(1/(a*c)^(1/2)*c*x)*A+1/2/c/(a*c)^(1/2)*arctan
(1/(a*c)^(1/2)*c*x)*C

________________________________________________________________________________________

maxima [A]  time = 0.96, size = 62, normalized size = 0.90 \[ -\frac {B a + {\left (C a - A c\right )} x}{2 \, {\left (a c^{2} x^{2} + a^{2} c\right )}} + \frac {{\left (C a + A c\right )} \arctan \left (\frac {c x}{\sqrt {a c}}\right )}{2 \, \sqrt {a c} a c} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((C*x^2+B*x+A)/(c*x^2+a)^2,x, algorithm="maxima")

[Out]

-1/2*(B*a + (C*a - A*c)*x)/(a*c^2*x^2 + a^2*c) + 1/2*(C*a + A*c)*arctan(c*x/sqrt(a*c))/(sqrt(a*c)*a*c)

________________________________________________________________________________________

mupad [B]  time = 0.10, size = 60, normalized size = 0.87 \[ \frac {\mathrm {atan}\left (\frac {\sqrt {c}\,x}{\sqrt {a}}\right )\,\left (A\,c+C\,a\right )}{2\,a^{3/2}\,c^{3/2}}-\frac {\frac {B}{2\,c}-\frac {x\,\left (A\,c-C\,a\right )}{2\,a\,c}}{c\,x^2+a} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((A + B*x + C*x^2)/(a + c*x^2)^2,x)

[Out]

(atan((c^(1/2)*x)/a^(1/2))*(A*c + C*a))/(2*a^(3/2)*c^(3/2)) - (B/(2*c) - (x*(A*c - C*a))/(2*a*c))/(a + c*x^2)

________________________________________________________________________________________

sympy [A]  time = 0.65, size = 116, normalized size = 1.68 \[ - \frac {\sqrt {- \frac {1}{a^{3} c^{3}}} \left (A c + C a\right ) \log {\left (- a^{2} c \sqrt {- \frac {1}{a^{3} c^{3}}} + x \right )}}{4} + \frac {\sqrt {- \frac {1}{a^{3} c^{3}}} \left (A c + C a\right ) \log {\left (a^{2} c \sqrt {- \frac {1}{a^{3} c^{3}}} + x \right )}}{4} + \frac {- B a + x \left (A c - C a\right )}{2 a^{2} c + 2 a c^{2} x^{2}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((C*x**2+B*x+A)/(c*x**2+a)**2,x)

[Out]

-sqrt(-1/(a**3*c**3))*(A*c + C*a)*log(-a**2*c*sqrt(-1/(a**3*c**3)) + x)/4 + sqrt(-1/(a**3*c**3))*(A*c + C*a)*l
og(a**2*c*sqrt(-1/(a**3*c**3)) + x)/4 + (-B*a + x*(A*c - C*a))/(2*a**2*c + 2*a*c**2*x**2)

________________________________________________________________________________________